package com.sys.app.entity.sys;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.sys.app.entity.BaseEntity;

import java.util.List;

/**
 * 菜单表
 */
@TableName(value = "T_SYS_MENU")
public class SysMenu extends BaseEntity {
    /**
     * 菜单名称
     */
    private String name;
    /**
     * 父菜单ID
     */
    private Long  pid;

    /**
     * 图标类型
     */
    private String iconCls;
    /**
     * 菜单网址
     */
    private String  menuUrl;
    /**
     * 菜单排序
     */
    private Long menuOrder;

    /**
     * 菜单排序
     */
    private Integer status;

    /**
     * “state”:“closed”, open
     */
    @TableField(exist = false)
    private String state;

    @TableField(exist = false)
    private String text;

    /**
     * 子节点
     */
    @TableField(exist = false)
    private List<SysMenu> children;

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
        this.text=name;
    }

    public Long getPid() {
        return pid;
    }

    public void setPid(Long pid) {
        this.pid = pid;
    }

    public String getIconCls() {
        return iconCls;
    }

    public void setIconCls(String iconCls) {
        this.iconCls = iconCls;
    }

    public String getMenuUrl() {
        return menuUrl;
    }

    public void setMenuUrl(String menuUrl) {
        this.menuUrl = menuUrl;
    }

    public Long getMenuOrder() {
        return menuOrder;
    }

    public void setMenuOrder(Long menuOrder) {
        this.menuOrder = menuOrder;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public List<SysMenu> getChildren() {
        return children;
    }

    public void setChildren(List<SysMenu> children) {
        this.children = children;
    }

    public String getState() {
        return state;
    }

    public void setState(String state) {
        this.state = state;
    }

    public String getText() {
        return text;
    }
}
